<?php

header("Content-Type:text/html;charset=UTF-8");
require_once('kp.class.php');
require_once("config.php");

$kp = new kp(CONSUMER_KEY,CONSUMER_SECRET);

$oauth = $kp->OAuth();
if ($kp->errstr){
        die("OAuth认证失败:".$kp->errstr);
}else{
    echo '<h1>请将下面的内容保存到 kp_oauth.php,不含本行</h1><pre>';
    echo json_encode ($oauth);
    echo '</pre>';
}